package com.kukudb.asaproject.repository;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.kukudb.asaproject.pojo.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

@Repository     //spring bean  访问层的接口
@Mapper        //mybatis mapper
public interface UserRepository extends BaseMapper<User> {

    @Select("SELECT * FROM users WHERE user_name = #{userName} AND password = #{password}")
    User findUserByUsernameAndPassword(String userName, String password);
}
